package com.javakc.platform.modules.circle.topic.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.javakc.platform.components.base.entity.Base;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;

/**
* @author zhouhonggang
* @version 1.0.0
* @project rapid-development-platform
* @datetime 2022-04-16
* @description: [圈子话题·属性]
*/
@Getter
@Setter
@TableName("circle_topic")
@ApiModel(value = "CircleTopic对象", description = "圈子话题")
public class CircleTopic extends Base {
    @ApiModelProperty("标题")
    @NotBlank(message = "标题不可为空")
    @Length(min = 2, max = 50, message = "标题长度要求在{min}到{max}之间")
    private String title;
    @ApiModelProperty("感想")
    @NotBlank(message = "感想不可为空")
    @Length(min = 2, max = 50, message = "感想长度要求在{min}到{max}之间")
    private String thinks;
    @ApiModelProperty("类型")
    @NotNull(message = "类型不可为空")
    @Range(min = 2, max = 5, message = "数字要求在{min}到{max}之间")
    private Integer type;
    @ApiModelProperty("圈子外键")
    @NotNull(message = "圈子外键不可为空")
    @Range(min = 2, max = 5, message = "数字要求在{min}到{max}之间")
    private Integer circleInfoId;
    @ApiModelProperty("是否发布")
    @NotNull(message = "是否发布不可为空")
    @Range(min = 2, max = 5, message = "数字要求在{min}到{max}之间")
    private Integer publish;
}